<link rel="stylesheet" type="text/css" href="dist/css/page/view360.css">
<div class="cont">
    <div class="position" ng-show="!showType">
        <img alt="位置图标" src="dist/images/position.png" />view360&gt;客户详情
    </div>
    <div class="position" ng-show="showType == 'pay'">
        <img alt="位置图标" src="dist/images/position.png" />view360&gt;付款记录
    </div>
    <div class="position" ng-show="showType == 'contact'">
        <img alt="位置图标" src="dist/images/position.png" />view360&gt;合同记录
    </div>
    <!--客户信息-->
    <div ng-show="!showType" class="custom_360">
        <h2> 
            <img src="dist/images/360_admin.png" alt="" />
            <span>{{customerinfo.customername}}({{customerinfo.customer_code}})</span>
            <button class="change fr" ng-click="editCustomer()">编辑敏感信息</button>
        </h2>
        <div class="cus_commit" ng-show="customerinfo.combineto_id">
            已于{{customerinfo.combine_time}}被合并到<a ng-click="openDetail('View360',customerinfo.combineto_id)">{{customerinfo.combineto_name}}</a>
        </div>
        <div class="cus_commit" ng-show="combinFromInfoCount">
            <div ng-repeat="vinfo in combinFromInfo">
                <a ng-click="openDetail('View360',vinfo.customer_id)">{{vinfo.nickname}}</a>
            已于{{vinfo.combine_time}}合并到该客户
            </div>
        </div>
        <div class="ui form cus_divider">
            <div class="three fields">
                <div class="inline field"><b>累计服务时长：</b><span>{{servicedDay}}天</span></div>
                <div class="inline field"><b>资金量(万)：</b><span>{{customerinfo.mount}}</span></div>
                <div class="inline field"><b>联系方式：</b><span>{{customerinfo.phone}}</span></div>
            </div>
            <div class="three fields">
                <div class="inline field edit_field" ng-dblclick="changeSalPer()">
                    <b style="margin-right: 2.7em;" class="fl">服务人员：</b>
                    <div class="ui input" id="sales_person">{{customerinfo.sales_name}}</div>
                    <img src="dist/images/pen.png" ng-show="SPErights" class="cus_pen"/>
                    <input type="hidden" id="sales_person_edit" name="sales_person"/>
                    <div angucomplete-alt id="sales_personname" name="sales_person" style="width:180px;float:left;display:none; margin-left: -5px;" placeholder="服务人员" pause="100" selected-object="selectePerson" local-data="selectePersonList" search-fields="nickname" input-changed="personInputChanged"  title-field="nickname" maxlength="12"
                    minlength="1" input-class="form-control form-control-small" match-class="highlight" focus-first = 'true'
                    focus-in="focusIn()" focus-out="focusOut()" field-required="true" input-name="nickname">
                    </div>
                </div>
                <div class="inline field edit_field">
                    <b style="margin-right: 3.6em;">团队：</b><span>{{customerinfo.sub_company_name}}</span>
                </div>
            </div>
        </div>
        <h4>服务中合同</h4>
        <div class="ui five column grid" ng-repeat="vcontract in onServicecCntract"> 
            <div class="three wide column">
                <div>
                    <b>合同编号：</b>
                    <span>{{vcontract.order_num}}</span>
                </div>
            </div>
            <div class="three wide column">
                <div>
                    <b>合同金额：</b>
                    <span>{{vcontract.mount}}元</span>
                </div>
            </div>
            <div class="three wide column">
                <div>
                    <b>产品名称：</b>
                    <span>{{vcontract.productname}}</span>
                </div>
            </div>
            <div class="four wide column">
                <div>
                    <b>起始时间：</b>
                    <span>{{vcontract.start_time}}</span>至<span>{{vcontract.end_time}}
                </div>
            </div>
            <div class="three wide column cus_red">
                <div>剩余 <span>{{vcontract.remainDays}}</span> 天</div>
            </div>
        </div>
        <div ng-show="!onServiceCount" class="ui five column grid">
            <div class="three wide column" style="margin-top: 5px;"><b>当前无服务中合同</b></div>
        </div>
    </div>
    <div ng-show="!showType" class="cont_bottom clearfix">
        <!--客户基本信息-->
        <div class="info_360 fl">
            <div class="ui top attached tabular menu">
                <a class="active item" data-tab="first" ng-click="first()">基本信息</a>
                <a class="item" data-tab="second" ng-click="second()">沟通记录</a>
            </div>
            <!--基本信息-->
            <div class="ui bottom attached tab active" data-tab="first" id="showCusInfo">
                <div class="edit_title">双击需要修改的信息项即可进行修改</div>
                <div class="basic ui form">
                    <div class="two fields">
                        <div class="inline field">
                            <b>客户姓名</b>
                            <div class="ui input">{{infos.customername}}</div>
                        </div>
                        <div class="inline field messAge edit">
                            <b>所在地</b>
                            <div class="ui input cus_edit" id="local_width" ng-show="BErights" name="location">{{infos.location}}</div>
                            <div class="ui input" ng-show="!BErights" name="location">{{infos.location}}</div>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                        </div>
                    </div>
                    <div class="two fields">
                        <div class="inline field" ng-dblclick="changeShow('sex')">
                            <b class="fl" style="margin-right: 1.2em">性别</b>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                            <div name="sex" id="sex" style="width:160px;">{{infos.sexname}}</div>
                            <div class="ui selection dropdown" style="width:160px;float:left;display:none; margin-left: -5px;" id="sex_input">
                                <input type="hidden" id="sex_hide">
                                <div class="default text">请选择性别</div>
                                <i class="dropdown icon"></i>
                                <div class="menu">
                                    <div class="item" data-value="{{sel.k}}"  ng-repeat="sel in sextypes" ng-click="getParamValue('sex',sel.k)">{{sel.v}}</div>
                                </div>
                            </div>
                        </div>
                        <div class="inline field">
                            <b>资金量(万)</b>
                            <div class="ui input cus_edit" ng-show="BErights" name="mount">{{infos.mount}}</div>
                            <div class="ui input" ng-show="!BErights" name="mount">{{infos.mount}}</div>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                        </div>
                    </div>
                    <div class="two fields">
                        <div class="inline field">
                            <b class="fl" style="margin-right: 1.2em">出生年月</b>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                            <div name="birthday" id="birthdayOk" ng-dblclick="changeShow('birthdayOk')" ng-show="infos.birthday">{{infos.birthday}}</div>
                            <div name="birthday" id="birthdayNo" ng-dblclick="changeShow('birthdayNo')" ng-show="!infos.birthday">未知</div>
                            <div class="ui left icon input"  style="display:none;" id="birthday_input">
                                <input type="text" name="birthday_input" ng-model="infos.birthday" id="birthEditVal" placeholder="请选择出生年月" datetimepicker  format='YYYY-MM-DD' class="ui left icon input" style="width: 160px;height:32px;" ng-change="getBirthValue()">
                                <i class="calendar icon"></i>
                            </div>
                        </div>
                        <div class="inline field" ng-dblclick="changeShow('education')">
                            <b class="fl" style="margin-right: 1.2em;">教育程度</b>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                            <div name="education" id="education" style="width:180px">{{infos.edu_name}}</div>
                            <div class="ui selection dropdown" style="width:180px;float:left;display:none; margin-left: -5px;" id="education_input">
                                <input type="hidden" id="education_hide">
                                <div class="default text">请选择教育程度</div>
                                <i class="dropdown icon"></i>
                                <div class="menu">
                                    <div class="item" data-value="{{sel.k}}"  ng-repeat="sel in educationTypes" ng-click="getParamValue('education',sel.k)">{{sel.v}}</div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="two fields">
                        <div class="inline field" ng-dblclick="changeShow('career')">
                            <b class="fl" style="margin-right: 1.2em">职业信息</b>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                            <div name="career" id="career" style="width:180px">{{infos.car_name}}</div>
                            <div class="ui selection dropdown" style="float:left;display:none; margin-left: -5px;" id="career_input" tabindex="1">
                                <input type="hidden" id="career_hide">
                                <div class="default text">请选择教育程度</div>
                                <i class="dropdown icon"></i>
                                <div class="menu">
                                    <div class="car item" data-value="{{sel.k}}"  ng-repeat="sel in careerTypes" ng-click="getParamValue('career',sel.k)">{{sel.v}}</div>
                                </div>
                            </div>
                        </div>
                        <div class="inline field">
                            <b>渠道</b>
                            <span>{{infos.source_name}} </span>
                        </div>
                    </div>
                    <div class="fields">
                        <div class="inline field" style="width: 96%;">
                            <div style="float:left;">
                                <b>地址</b>
                            </div>
                            <span class="ui input cus_long cus_edit" id="address_width" ng-show="BErights" name="address">{{infos.address}}</span>
                            <span class="ui input cus_long" ng-show="!BErights" name="address">{{infos.address}}</span>
                            <img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/>
                        </div>
                    </div>
                    <div ng-dblclick="changeShow('remark')" id="remarkBox">
                        <div style="float:left;">
                            <label>
                                <b>备注信息</b>
                            </label>
                        </div>
                        <label><img src="dist/images/pen.png" ng-show="BErights" class="cus_pen"/></label>
                        <div style="padding: 0px 11px 11px 98px;" id="remark">{{infos.remark}}</div>
                        <div style="display:none;"><textarea rows="2" ng-model="infos.remark" maxlength="250" ng-blur="saveRemark()">{{infos.remark}}</textarea></div>
                    </div>
                
                    <h3>联系信息</h3>
                    <div class="two fields">
                        <div class="inline field">
                            <b>QQ</b>
                            <div class="ui input" name="qq">{{infos.qq}}</div>
                        </div>
                        <div class="inline field">
                            <b>微信</b>
                            <div class="ui input" name="weixin_id">{{infos.weixin_id}}</div>
                        </div>
                    </div>
                    <div class="two fields">
                        <div class="inline field">
                            <b>电话号码</b>
                            <div class="ui input" name="phone">{{infos.phone}}</div>
                        </div>
                    </div>
                    <h3>电话号码保存历史</h3>
                    <div class="two grey fields" ng-repeat="vphone in phoneInfo">
                        <div class="field">
                            <b>电话号码{{vphone.i}}</b>
                            <span>{{vphone.book_phone}}</span>
                        </div>
                    </div>
                </div>
            </div>
            <!--沟通记录-->
            <div class="ui bottom attached tab" data-tab="second">
                <div class="ui secondary  menu">
                    <a class="active item" data-tab="dailyContacts" ng-click="dailyContacts()">日常沟通({{dailyContactCount}})</a>
                    <a class="item" data-tab="dailyPhones" ng-click="dailyPhones()">日常电话({{dailyPhoneCount}})</a>
                    <!-- <a class="item" data-tab="weixin" ng-click="weixin()">微信记录()</a> -->
                    <a class="item" data-tab="complains" ng-click="complains()" ng-show="FKrights">400记录({{complainCount}})</a>
                    <a class="item" data-tab="risks" ng-click="risks()" ng-show="FKrights">追踪记录({{riskCount}})</a>
                    <a class="item" data-tab="wenjuan" ng-click="wenjuan()">问卷记录({{wenjuanCount}})</a>
                </div>
                <!--日常沟通-->
                <div class="ui secondcont tab active" data-tab="dailyContacts">
                    <form action="#" name="frm-addContact" id="frm-addContact">
                        <textarea  rows="3" name="content" id="addContent" ng-Model="contentAdd" class="day_content" placeholder="请填写沟通记录" ng-blur="hideError()"></textarea>
                        <div class="fields">     <!--错误提示-->
                            <div id="showError"></div>
                        </div>
                    </form>
                    <div>
                        <div>
                            <button ng-click="addContacts()" class="day_record">添加</button>
                        </div>
                    </div>
                    <div style="min-height: 315px;">
                        <div class="record_400" ng-repeat="contact in dailyContactData">
                            <img src="dist/images/dot.png" class="dot"/>
                            <div class="phone_time">沟通时间：{{contact.create_time}}</div>
                            <div>沟通人：{{contact.contact_name}}</div>
                            <div id="contactContent_{{contact.contact_id}}">沟通内容：{{contact.content}}</div>
                        </div>
                    </div>
                    
                    <div ng-if="dailyContactPages.pageAll >1" class="ui pagination fr menu" jspagination page-object="dailyContactPages" page-func="dailyContactInfo">
                    </div>
                </div>
                <!--日常电话-->
                <div class="ui secondcont tab" data-tab="dailyPhones">
                    <div style="min-height: 465px;">
                        <div class="record_400" ng-repeat="phone in dailyPhoneData">
                            <img src="dist/images/dot.png" class="dot"/>
                            <div class="phone_time">起始时间：{{phone.begintime}}  至 {{phone.endtime}}</div>
                            <div>接听人员：{{phone.nickname}} </div>
                            <div class="calltime">通话时长：{{phone.calltime}}
                                <!-- <img src="dist/images/play.png" alt="" /> -->
                            </div>
                        </div>
                    </div>
                    <div ng-if="dailyPhonePages.pageAll >1 && phoneRcode==1" class="ui pagination fr menu" jspagination page-object="dailyPhonePages" page-func="dailyPhoneInfo">
                    </div>
                </div>
                <!--微信记录-->
                <div class="ui secondcont tab" data-tab="weixin" style="margin: 0 24px;">
                    <div class="ui accordion wx">
                        <div class="active title">
                            <img src="dist/images/dot.png" alt="" />
                            <strong>业务员：张秋雨 </strong>
                            <img src="dist/images/calendar.png"/>
                            <i class="angle down icon fr"></i>
                            <span class="fr">共100条 </span>
                        </div>
                        <div class="active content">
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                        </div>
                        <div class="title">
                            <img src="dist/images/dot.png" alt="" />
                            <strong>业务员：张秋雨 </strong>
                            <img src="dist/images/calendar.png"/>
                            <i class="angle down icon fr"></i>
                            <span class="fr">共19条 </span>
                        </div>
                        <div class="content">
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                        </div>
                        <div class="title">
                            <img src="dist/images/dot.png" alt="" />
                            <strong>业务员：张秋雨 </strong>
                            <img src="dist/images/calendar.png"/>
                            <i class="angle down icon fr"></i>
                            <span class="fr">共3条 </span>
                        </div>
                        <div class="content">
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                                <div>【活跃】 深圳-向晚</div>
                                <div>求semantic邀请码一个</div>
                        </div>
                    </div>
                </div>
                <!--400记录-->
                <div class="ui secondcont tab" data-tab="complains">
                    <div style="min-height: 465px;">
                        <div class="record_400" ng-repeat="complain in complainData">
                            <img src="dist/images/dot.png" class="dot"/>
                            <div class="phone_time">来电时间：{{complain.create_time}}</div>
                            <div>来电类型：{{complain.incoming_name}}</div>
                            <div>来电内容：{{complain.content}}</div>
                            <div>最近处理时间：{{complain.up_time}}</div>
                            <div>处理状态：{{complain.status_name}}</div>
                        </div>
                    </div>
                    <div ng-if="complainPages.pageAll >1 && complainRcode==1" class="ui pagination fr menu" jspagination page-object="complainPages" page-func="complainInfos">
                    </div>
                </div>
                <!--追踪记录-->
                <div class="ui secondcont tab" data-tab="risks">
                    <div style="min-height: 465px;">
                        <div class="record_400" ng-repeat="risk in riskData">
                            <img src="dist/images/dot.png" class="dot"/>
                            <div class="phone_time">追踪时间：{{risk.confirm_time}}</div>
                            <div>来电问题：{{risk.description}}</div>
                            <div>相关人员反馈：{{risk.reply}}</div>
                            <div>追踪结果：{{risk.reply_confirm}}</div>
                            <div>处理状态：{{risk.status_name}}</div>
                        </div>
                    </div>
                    <div ng-if="riskPages.pageAll >1 && riskRcode==1" class="ui pagination fr menu" jspagination page-object="riskPages" page-func="riskInfos">
                    </div>
                </div>
                <!--问卷记录-->
                <div class="ui secondcont tab" data-tab="wenjuan">
                    <div style="min-height: 465px;">
                        <div class="record_400" ng-repeat="wenjuan in wenjuanData">
                            <img src="dist/images/dot.png" class="dot"/>
                            <div class="phone_time">填写时间：{{wenjuan.create_time}}</div>
                            <div>回执编号：{{wenjuan.survey_code}}</div>
                            <div>类型：{{wenjuan.rank_title}}</div>
                            <div>分数：{{wenjuan.rank}}</div>
                        </div>
                    </div>
                    <div ng-if="wenjuanPages.pageAll >1 && wenjuanRcode==1" class="ui pagination fr menu" jspagination page-object="wenjuanPages" page-func="wenjuanInfo">
                    </div>
                </div>
            </div>
        </div>
        <!--客户相关-->
        <div class="about_360 fr">
            <h3>相关</h3>
            <div class="links">
                <a href="javascript:void(0)">付款记录({{payCount}})</a>
                <a href="javascript:void(0)">合同记录({{contractCount}})</a>
                <a href="javascript:void(0)">荐股历史(0)</a>
            </div>
            <!--付款、合同记录-->
            <div class="ui accordion">
                <div class="active title">
                    <img src="dist/images/360_pay.png"/>
                    <b>付款记录({{payCount}})</b><a ng-click="openDetail('View360',customer_id+'_pay')">更多</a>
                    <i class="angle down icon fr"></i>
                </div>
                <div class="active content">
                    <ul>
                        <li ng-repeat="vpayTwo in payInfoTwoDate">
                            <div><b>合同编号：{{vpayTwo.order_num}}</b></div>
                            <div>订购产品：{{vpayTwo.productName}}</div>
                            <div class="cus_order clearfix">
                                <div class="fl">付款金额：{{vpayTwo.pay_mount}}元</div>
                                <div class="fl">付款时间：{{vpayTwo.pay_time}}</div>
                                <div class="fl">状态：
                                    <span pay-status status="{{::vpayTwo.status}}"></span>
                                    <!-- {{vpayTwo.auditname}} -->
                                </div>
                            </div>
                        </li>
                    </ul>
                </div>
                <div class="title">
                    <img src="dist/images/360_contract.png" alt="" /><b>合同记录({{contractCount}})</b>
                    <a ng-click="openDetail('View360',customer_id+'_contact')">更多</a>
                    <i class="angle down icon fr"></i>
                </div>
                <div class="content">
                    <ul class="cus_record">
                        <li ng-repeat="vcontractTwo in contractInfoTwoDate">
                            <div>
                                <b>合同编号：{{vcontractTwo.order_num}}
                                <a class="look fr" ng-click="showContractDetail(vcontractTwo.contract_id)">查看</a>
                                </b>
                            </div>
                            <div>订购产品：{{vcontractTwo.productname}}</div>
                            <div>合同金额：{{vcontractTwo.paymount}}元</div>
                            <div>合同时间：{{vcontractTwo.start_time}}至{{vcontractTwo.end_time}}</div>
                            <div>业务人员：{{vcontractTwo.sales_name}}</div>
                            <div>状态：<span contract-status state="{{vcontractTwo.state}}"></span></div>
                        </li>
                    </ul>
                </div>
                <div class="title">
                    <img src="dist/images/360_history.png" alt="" /><b>荐股历史(0)</b><a href="">更多</a>
                    <i class="angle down icon fr"></i>
                </div>
                <div class="content">
                    
                </div>
            </div>
        </div>
    </div>

    <!-- 付款记录-->
    <div ng-show="showType == 'pay'">
        <div class="menus_table">
            <table class="ui yellow celled striped table">
                <thead>
                    <tr>
                        <th>订购产品</th>
                        <th>付款人</th>
                        <th style="width:10%;">付款金额(元)</th>
                        <th style="width:15%;">订单编号</th>
                        <th>付款时间</th>
                        <th>付款方式</th>
                        <th>业务人员</th>
                        <th>状态</th>
                        <th>审核信息</th>
                        <th>备注</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="vfukuan in fukuanInfo">
                        <td>{{vfukuan.productName}}</td>
                        <td>{{vfukuan.pay_name}}</td>
                        <td style="text-align: right">{{vfukuan.pay_mount}}</td>
                        <td>{{vfukuan.pay_order}}</td>
                        <td>{{vfukuan.pay_time}}</td>
                        <td>{{vfukuan.pay_way}}</td>
                        <td>{{vfukuan.nickname}}</td>
                        <td pay-status status="{{::vfukuan.status}}"></td>
                        <td>{{vfukuan.audit_msg}}</td>
                        <td>{{vfukuan.remark}}</td>
                    </tr>
                </tbody>
                <tbody ng-show="rcode_fukuan==2">
                    <tr ng-show="!busy">
                        <td colspan="6" style="text-align:center;margin-top:10px" class="null_data">没有找到数据~~~</td>
                    </tr>
                </tbody>
            </table>
            <div ng-if="fukuanPages.pageAll >1 && rcode_fukuan==1" class="ui pagination fr menu" jspagination page-object="fukuanPages" page-func="getFukuanList">
            </div>
        </div>
    </div>

    <!-- 合同记录 -->
    <div ng-show="showType == 'contact'">
        <div class="menus_table">
            <table class="ui yellow celled striped table">
                <thead>
                    <tr>
                        <th>订购产品</th>
                        <th style="width:18%;">付款金额(元)</th>
                        <th>开始时间</th>
                        <th>结束时间</th>
                        <th>业务人员</th>
                        <th>状态</th>
                        <th>操作</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="vcontacts in contactsInfo">
                        <td>{{vcontacts.productname}}</td>
                        <td style="text-align: right">{{vcontacts.paymount}}</td>
                        <td>{{vcontacts.start_time}}</td>
                        <td>{{vcontacts.end_time}}</td>
                        <td>{{vcontacts.sales_name}}</td>
                        <td contract-status state="{{vcontacts.state}}"></td>
                        <td><a ng-click="showContractDetail(vcontacts.contract_id)">查看</a></td>
                    </tr>
                </tbody>
                <tbody ng-show="rcode_contract==2">
                    <tr ng-show="!busy">
                        <td colspan="7" style="text-align:center;margin-top:10px" class="null_data">没有找到数据~~~</td>
                    </tr>
                </tbody>
            </table>
            <div ng-if="contractPages.pageAll >1 && rcode_contract==1" class="ui pagination fr menu" jspagination page-object="contractPages" page-func="contractList">
            </div>
        </div>
    </div>

</div>


<!--编辑客户基本信息-->
<div class="ui editCustomer modal">
    <div class="header_h4">修改基本信息</div>
    <div class="content">
        <div class="ui form" style="margin-left: 16px;">
            <form action="#" name="frm-edit" id="frm-edit">
                <input type="hidden" name="customer_id" ng-model="customer_id" id="editCustomer_id">
                <div class="fields">
                    <div class="seven wide field required">
                        <label class="label_fl">客户名</label>
                        <input type="text" name="nickname" maxlength="15" placeholder="请填写客户名称" style="width:240px;margin-left: 0.3em"/>
                    </div>
                    <div class="one wide field"></div>
                    <div class="inline eight wide field">
                        <label>微信</label>
                        <input type="text" name="weixin_id" maxlength="15" placeholder="请填写微信号" style="width:240px;"/>
                    </div>
                </div>
                <div class="fields">
                    <div class="seven wide field" id="phone_edit">
                        <label class="label_fl">电话号码</label>
                        <input type="hidden" name="checkPhone" id="checkPhone">
                        <input type="text" name="phone" ng-model="phone" maxlength="15" placeholder="请填写电话号码" style="width:240px"/>
                    </div>
                    <div class="one wide field"></div>
                    <div class="inline field">
                        <label>QQ</label>
                        <input type="text" name="qq" placeholder="请填写QQ号码" maxlength="14" style="width:240px;margin-left: 0.2em"/>
                    </div>
                </div>
                <div class="inline fields" style="margin-top:15px; margin-left: 0">
                    <div class="field required">
                        <label>是否要保存到保存历史</label>
                    </div>
                    <div class="field">
                        <div class="ui radio checkbox">
                            <input name="storeOrNot" checked="checked" type="radio" value="1">
                            <label>是</label>
                        </div>
                    </div>
                    <div class="field" style="margin-left: 50px;">
                        <div class="ui radio checkbox">
                            <input name="storeOrNot" type="radio" value="2">
                            <label>否</label>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
    <div class="actions">
        <button class="ui green button positive">确认</button>
       <button class="ui grey button negative">取消</button>
    </div>
</div>

<!--编辑成功-->
<div class="ui small modal editOk" style="text-align: center;">
    <div class="header">提示</div>
    <div class="content">
        <i class="huge green check circle outline icon"></i>
        <p style="padding-top: 15px;">编辑成功</p>
    </div>
</div>
<!--编辑失败-->
<div class="ui modal editFail" style="text-align: center;">
    <div class="header">提示</div>
    <div class="content">
        <i class="huge red warning outline icon"></i>
        <p style="padding-top: 15px;">编辑失败</p>
    </div>
</div>
<!--权限弹窗-->
<div class="ui modal modalAdd time" style="text-align: center;">
    <div class="header">提示</div>
    <div class="content"> 
        <i class="huge red warning  outline icon "></i>
        <p style="padding-top: 15px;">沟通记录添加失败！</p>
    </div>
</div>
<!-- 非超级管理员不可编辑客户信息 -->
<div class="ui modal noRightEdit" style="text-align: center;">
    <div class="header">提示</div>
    <div class="content">
        <i class="huge red warning outline icon"></i>
        <p style="padding-top: 15px;">无权限编辑客户敏感信息</p>
    </div>
</div>
<script type="text/javascript">

    $('.ui.selection.dropdown').dropdown();
    function setHeight(){
       
    }
    function stopPropagation(e) {
        var ev = e || window.event;
        if (ev.stopPropagation) {
            ev.stopPropagation();
        }
        else if (window.event) {
            window.event.cancelBubble = true;//兼容IE
        }
    }
    $("#sex_input").click(function (e) {
        $('#sex').hide();
        $("#sex_input").show();
        stopPropagation(e);
    });
    $("#birthday_input").click(function (e) {
        $('#birthdayOk').hide();
        $('#birthdayNo').hide();
        $("#birthday_input").show();
        stopPropagation(e);
    });
    $("#education_input").click(function (e) {
        $('#education').hide();
        $("#education_input").show();
        stopPropagation(e);
    });
    $("#career_input").click(function (e) {
        $('#career').hide();
        $("#career_input").show();
        stopPropagation(e);
    });

    $(document).ready(function(){
        //tab菜单切换
        $('.menu .item').tab();
        //修改基本信息
        $('button.change').click(function(){
            $('.ui.change.modal').modal('show')
            $('.ui.change.modal lebal').css({width:"64px", display:"inline-block"})
        })
        //相关折叠菜单内容
        $('.about_360 .ui.accordion').accordion({
            selector: {trigger: '.title .icon,.title b'}
        });
        $('.links a').click(function(){
            $('.about_360 .ui.accordion').accordion('open',$(this).index())
        })
        
        //微信记录折叠菜单
        $('.ui.accordion.wx').accordion({
            selector: {trigger: '.title .icon'}
        });

    })
    $(function(){
        //判断输入电话号码是否已经存在
        $.fn.form.settings.rules.checkPhoneExist = function() {
            var isValid = true;
            var checkPhone = $('#frm-edit input[name="checkPhone"]').val();
            if(checkPhone == 'exist')
                isValid = false;
            return isValid;
        };

        //判断输入电话号码是否超过11位
        $.fn.form.settings.rules.checkPhoneOk = function() {
            var isValid = true;
            var checkPhone = $('#frm-edit input[name="checkPhone"]').val();
            if(checkPhone == 'ok')
                isValid = true;
            else if(checkPhone == 'wrong')
                isValid = false;
            return isValid;
        }

        //判断输入电话号码是否少于7位
        $.fn.form.settings.rules.checkPhoneLength = function() {
            var isValid = true;
            var checkPhone = $('#frm-edit input[name="checkPhone"]').val();
            if(checkPhone == 'short')
                isValid = false;
            return isValid;
        }

        /*编辑客户基本信息--表单验证*/
        $('#frm-edit').form({
            on: 'blur',
            inline: true,
            fields: {
                nickname: {
                    identifier: 'nickname',
                    rules: [{
                        type: 'empty',
                        prompt: '客户名不能为空'
                    }]
                },
                phone: {
                    identifier: 'phone',
                    rules: [
                        {
                            type   : 'number',
                            prompt : '电话号码必须是数字'
                        },{
                            type   : 'checkPhoneLength',
                            prompt : '电话号码不能少于7位数字'
                        },{
                            type   : 'checkPhoneOk',
                            prompt : '若为手机号码，请输入11位'
                        },{
                            type   : 'checkPhoneExist',
                            prompt : '电话号码已经存在'
                        }
                    ]
                },
                mount: {
                    identifier: 'mount',
                    rules: [{
                        type: 'number',
                        prompt: '资金量必须为数字'
                    }]
                },
            }
        });
    });
</script>